<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
     pageEncoding="ISO-8859-1"%>
<%@ page import = "javax.servlet.http.HttpSession" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.css">
<title>AdminPanel</title>

</head>
	<body>
		<% 
		String un = (String) session.getAttribute("name");
		if(un!=null){ %>
		
			<nav class="navbar navbar-default navbar-fixed-top " role="navigation">
			<div class="container-fluid">
				<div class="navbar-header">
				<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
        		<span class="sr-only">Toggle navigation</span>
        		<span class="icon-bar"></span>
        		<span class="icon-bar"></span>
        		<span class="icon-bar"></span>
      			</button>
      			</div>
   					<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
      <ul class="nav navbar-nav navbar-right">
      <li><a href="LogOut">LogOut</a></li>
      </ul></div>
		</nav><br><br><br>
		
		<div class="container">

    	<div class="banner">
    	<h2 class="text-center login-title" >EZRiceMillSystem</h2>
    	<div class="col-sm-2 col-md-4 col-md-offset-4">
	<h4 class="text-center login-title">Welcome Admin</h4>
  		<div class="col-sm-4 col-md-8 col-md-offset-2">
  		<div class="well">
    		 <div class="account-wall">
<style>
	.navbar-header {
    float: left;
    padding: 5px;
    text-align: center;
    width: 95%;
}
.navbar-brand {float:none;}	
</style>
<div class="btn-group">
<form name="adminpanel" action = "AdminPanel" method="post">

    <button class="btn" name="action" value="Register">Register</button> 
    <button class="btn" name="action" value="Delete">Delete</button> 
</form> 
</div><%}
else{  
	out.println("<script type=\"text/javascript\">");
	   out.println("alert('Please login first');");
	   out.println("location='index.jsp';");
	   out.println("</script>");
	}
		//out.print("Please login first");    
            //request.getRequestDispatcher("index.jsp").include(request, response);  
         
         %>
        </div>
         </div>
          </div>
           </div>
            </div>
             </div>

</body>
</html>